package com.byComputer.bo;

import java.io.Serializable;

import com.byComputer.vo.Computer;

/**
 * 购物票：包含了所购物品的数量和详情
 * 
 * @author WangPeihu
 * 
 */
public class CartItem implements Serializable{
	private Computer computer; // 包含了电脑的信息
	private int number; 					// 还包含了电脑的数目

	public Computer getComputer() {
		return this.computer;
	}

	public void setComputer(Computer computer) {
		this.computer = computer;
	}

	public int getNumber() {
		return number;
	}

	public void setNumber(int number) {
		this.number = number;
	}

	public static void main(String[] args) {
		ComputerService computer = new ComputerService();
		Computer cc = computer.getComputer(1);
		CartItem cItem = new CartItem();
		cItem.setComputer(cc);
		String id = cItem.getComputer().getDescription();
		System.out.println(id);
	}
}
